home *** CD-ROM | disk | FTP | other *** search
/ Shareware Overload Trio 2 / Shareware Overload Trio Volume 2 (Chestnut CD-ROM).ISO / dir39 / bcmd20.zip / BCMD.DOC < prev    next >
Text File  |  1994-11-05  |  27KB  |  893 lines

  1.       BCMD  Copyright (c) 1993-1994  Thomas G. Hanlin III
  2.       =-------------------------------------------------=
  3.            The Better Command Utilities, version 2.0
  4.  
  5.  
  6.  
  7. The Better Command Utilities, or BCMD, is a set of commands
  8. which provide improved replacements for existing DOS commands
  9. (like DIR and COPY) and many entirely new commands as well. BCMD
  10. may be used instead of, or along with, existing DOS commands.
  11.  
  12. BCMD offers many improvements over the default DOS commands.
  13. These include multiple file specifications on a single command
  14. line, exception filespecs, directory colorization, 132-column
  15. support, test modes, support for file descriptions and other
  16. goodies. Help is built into each command and will be displayed
  17. if you use the /? switch.
  18.  
  19. The BCMD collection is copyrighted. It may be distributed only
  20. under the following conditions:
  21.  
  22.    All BCMD files must be distributed together as a unit.
  23.    No files may be altered, added, or deleted from this unit.
  24.  
  25. YOU USE BCMD ENTIRELY AT YOUR OWN RISK. It works for me on the
  26. computers I've tried it on. I can't guarantee it will do the
  27. same for you.
  28.  
  29. BCMD is not free software. If you find this evaluation copy
  30. suited to your needs, send in your registration. The ORDER.FRM
  31. file gives complete ordering information.
  32.  
  33.                       Table of Contents                 page 2
  34.  
  35.  
  36.  
  37.  Overview and Legal Info ................................... 1
  38.  
  39.  General Notes ............................................. 3
  40.  
  41.  BCHOICE (batch input) ..................................... 4
  42.  BCOPY (copy file) ......................................... 5
  43.  BDEL (delete file) ........................................ 6
  44.  BDIR (file directory) ..................................... 7
  45.  BEEP (sound effects)....................................... 8
  46.  BMD (make directory) ...................................... 9
  47.  BRD (remove directory) .................................... 9
  48.  BREN (rename file) ....................................... 10
  49.  BTYPE (display file) ..................................... 11
  50.  
  51.  CAL (calendar) ........................................... 11
  52.  CALC (calculator) ........................................ 12
  53.  CAPSLOCK (Caps Lock setting) ............................. 12
  54.  COLOR (set display colors) ............................... 13
  55.  
  56.  DESCRIBE (describe file) ................................. 14
  57.  
  58.  ECHOS (echo w/o CR/LF) ................................... 15
  59.  
  60.  FREE (show disk space) ................................... 15
  61.  
  62.  KEYSPEED (set keyboard speed) ............................ 16
  63.  
  64.  LOCASE (lowercase filter) ................................ 16
  65.  LOCATE (set cursor position) ............................. 17
  66.  LTRIM (left trim filter) ................................. 17
  67.  
  68.  NUMLOCK (Num Lock setting) ............................... 18
  69.  
  70.  ONESPACE (one space filter) .............................. 18
  71.  
  72.  TYME (time and date) ..................................... 19
  73.  
  74.  UNANSI (remove ANSI filter) .............................. 19
  75.  UNCPM (remove Ctrl-Z EOFs) ............................... 20
  76.  UPCASE (uppercase filter) ................................ 21
  77.  
  78.                          General Notes                  page 3
  79.  
  80.  
  81.  
  82. The BCMD utilities which act as replacements for existing DOS
  83. commands are given names which start with "B" to differentiate
  84. them from the corresponding DOS command. These include:
  85.  
  86.    BCHOICE, BCOPY, BDEL, BDIR, BMD, BRD, BREN, BTYPE
  87.  
  88. These commands act much like the DOS commands they're based on,
  89. by default. You can customize them with additional capabilities
  90. using command-line options and/or environment variables.
  91.  
  92. Like DOS, BCMD will normally display filenames in uppercase. You
  93. can change this to lowercase for all of the BCMD utilities by
  94. setting a BCMD environment variable:
  95.  
  96.    SET BCMD=/L
  97.  
  98. Place that SET line in your AUTOEXEC.BAT file if you'd like to
  99. install it automatically whenever you start your computer.
  100.  
  101. If you don't want the status reporting that most BCMD commands
  102. give you as a matter of course, you can also turn it off with
  103. the BCMD environment variable, using the /Q (quiet) switch.
  104.  
  105. Individual BCMD commands will often have their own environment
  106. variables so you can customize them to your preferences. These
  107. will be discussed in the documentation for each command.
  108.  
  109. Some BCMD commands support color. For color support to work, you
  110. must have an ANSI driver (such as ANSI.SYS) installed. See your
  111. DOS manual for details on ANSI if BCMD displays odd characters
  112. instead of color.
  113.  
  114. BCMD file descriptions are maintained in a format compatible
  115. with the 4DOS and NDOS command shells.
  116.  
  117. BCMD disk access remains to be optimized. Some commands in some
  118. configurations will be noticeably slow on floppy drives.
  119.  
  120.                             BCHOICE                     page 4
  121.  
  122.  
  123.  
  124. The CHOICE command debuted in MS-DOS 6.0, when Microsoft finally
  125. noticed that interactive batch files might be handy. It is a
  126. flexible input command that allows you to specify a list of
  127. valid responses and a timeout in case no one is present. The
  128. BCHOICE command works the same way, but for any DOS version.
  129.  
  130. Syntax:
  131.    BCHOICE {options} {text}
  132.  
  133. Options:
  134.  
  135.    /C[:]keys    keys to accept
  136.    /N           no prompt
  137.    /S           case sensitive
  138.    /T[:]c,nnnn  default answer, seconds to wait for answer
  139.  
  140. If you do not specify which keys to accept, YN will be assumed.
  141. You may choose a default answer and the amount of time to wait
  142. for an answer (0-9999 seconds). The result is returned via the
  143. DOS error level: 1 for the first key listed, 2 for the second,
  144. etc; 0 if ^C or Break is pressed; 255 if syntax error.
  145.  
  146. The text prompt should be enclosed in quotation marks for best
  147. results. Otherwise, the text may be altered in various ways by
  148. the command-line parser.
  149.  
  150. Example:
  151.    BCHOICE /T:N,4 "Shall we play a game "
  152.  
  153. This example displays:
  154.  
  155. Shall we play a game [Y,N]?
  156.  
  157. ...and waits for up to four seconds for an answer, assuming "N"
  158. if no key is pressed.
  159.  
  160.                              BCOPY                      page 5
  161.  
  162.  
  163.  
  164. The BCOPY command is similar to the DOS command, COPY. It is a
  165. pure file-to-file copy command, however. It does not support
  166. devices or append operations.
  167.  
  168. Unlike the DOS command it replaces, BCOPY can accept multiple
  169. source and destination files, can copy hidden, read-only, and
  170. system files, accepts exception specifications, and allows
  171. prompting for confirmation before copying or before overwriting
  172. existing files.
  173.  
  174. When specifying multiple source or destination files, enclose
  175. them in parentheses so BCOPY can tell which is which.
  176.  
  177. Syntax:
  178.    BCOPY {options} [source(s)] [dest(s)] {/E [exception(s)]}
  179.  
  180. Options:
  181.    /E   copy everything EXCEPT for the following files
  182.    /H   copy hidden, read-only, and system files too
  183.    /L   display filenames in lowercase
  184.    /N   don't actually copy anything (for testing BCOPY)
  185.    /P   prompt for confirmation before copying each file
  186.    /Q   quiet: don't display filenames or summary
  187.    /R   prompt before overwriting existing files
  188.    /Y   assume YES to all requests for confirmation
  189.  
  190. The following parameters may be set as defaults for BCOPY by
  191. setting the BCOPY environment variable: /H /L /P /Q /R /Y
  192.  
  193. Example:
  194.    BCOPY (A: B:) C:\MISC
  195.  
  196. The above example copies all files on both A: and B: drives to
  197. the directory C:\MISC.
  198.  
  199. Example:
  200.    BCOPY *.* A: /E *.LTR *.TXT
  201.  
  202. The above example copies all files in the current directory to
  203. drive A:, except for files that end in .LTR or .TXT.
  204.  
  205.                              BDEL                       page 6
  206.  
  207.  
  208.  
  209. The BDEL command is similar to the DOS command, DEL (or ERASE).
  210.  
  211. Unlike the DOS command it replaces, BDEL can accept multiple
  212. file specs, can delete hidden, read-only, and system files,
  213. accepts exception specifications, and can recurse through an
  214. entire directory tree.
  215.  
  216. Syntax:
  217.    BDEL {options} [file(s)] {/E [exception file(s)]}
  218.  
  219. Options:
  220.    /E   delete everything EXCEPT for the following files
  221.    /H   delete hidden, read-only, and system files too
  222.    /L   display filenames in lowercase
  223.    /N   don't actually delete anything (for testing BDEL)
  224.    /P   prompt for confirmation before deleting each file
  225.    /Q   quiet: don't display filenames or summary
  226.    /S   recurse through subdirectories
  227.    /Y   assume YES to all requests for confirmation
  228.  
  229. The following parameters may be set as defaults for BDEL by
  230. setting the BDEL environment variable: /H /L /P /Q /Y
  231.  
  232. Example:
  233.    BDEL A: B: /E *.EXE
  234.  
  235. The above example deletes all files on both A: and B: drives,
  236. except for files ending in .EXE.
  237.  
  238. Example:
  239.    BDEL /H /P *.*
  240.  
  241. The above example deletes all files in the current directory,
  242. including hidden, read-only, and system files. It asks for
  243. confirmation before deleting each file.
  244.  
  245. Example:
  246.    BDEL /S C:\*.BAK
  247.  
  248. The above example deletes all files in every directory on the C:
  249. drive which end in the extension .BAK.
  250.  
  251.                              BDIR                       page 7
  252.  
  253.  
  254.  
  255. The BDIR command is similar to the DOS command, DIR.
  256.  
  257. Unlike the DOS command it replaces, BDIR can accept multiple
  258. file specs, can colorize its listing, supports 132 columns,
  259. allows descriptions to be tagged onto files, can show file
  260. attributes, and is highly configurable.
  261.  
  262. Syntax:
  263.    BDIR {options} {file(s)} {/E [exception file(s)]}
  264.  
  265. Options:
  266.    /A   attributes (any of ADHRS: Arc Dir Hid R/O Sys)
  267.    /B   bare list: filenames only, single column
  268.    /D   don't show dot directories ("." and "..")
  269.    /E   dir of everything EXCEPT for the following files
  270.    /K   suppress header (pathname, etc)
  271.    /L   display filenames in lowercase
  272.    /M   suppress footer (totals, etc)
  273.    /O   sorting order (any of DGNS: Date GroupDirs Name Size)
  274.    /P   prompt to continue at end of each full screen
  275.    /S   recurse through subdirectories
  276.    /T   display file attributes
  277.    /U   display only summary info
  278.    /W   wide list: filenames only, multiple columns
  279.    /X   extra wide output (132-column mode)
  280.    /Y   display file descriptions
  281.    /Z   colorize (defaults may be changed with COLORDIR vbl)
  282.  
  283. The following parameters may be set as defaults for BDIR by
  284. setting the BDIR environment variable:
  285.    /A /D /K /L /M /O /P /T /X /Y /Z
  286.  
  287. Example:
  288.    BDIR /Z /Y /OGN
  289.  
  290. The above example displays all files in the current directory,
  291. colorized, with descriptions (if any). Subdirectories are
  292. grouped before files, and it is sorted in alphabetical order.
  293.  
  294. The COLORDIR environment variable can be used to change the /Z
  295. option's colors. You may set colors based on file extensions and
  296. file attributes (attributes take precedence):
  297.  
  298.    SET COLORDIR=[extlist]:[color] {; [extlist]:[color]} {etc}
  299.  
  300. An "extlist" is a list of extensions or attributes, separated by
  301. spaces. Attributes are ARCHIVE, DIRS, SYSTEM, HIDDEN, RDONLY.
  302. Colors are the same as for the COLOR command, but background
  303. colors are not allowed.
  304.  
  305. Example:
  306.    SET COLORDIR=DOC TXT:BLUE;DIRS:BRIGHT GREEN;BAS:RED
  307.  
  308. The above example makes .DOC and .TXT files blue, directories
  309. bright green, and .BAS files red.
  310.  
  311.                              BEEP                       page 8
  312.  
  313.  
  314.  
  315. The BEEP command provides simple sound effects through the PC
  316. speaker.
  317.  
  318. Syntax:
  319.    BEEP {frequency duration}
  320.  
  321. The frequency is specified in Hertz (cycles per second). The
  322. duration is given in 1/18th seconds. No sound will be generated
  323. for frequencies below 20, allowing you to use this as a delay
  324. command as well.
  325.  
  326. If no parameters are specified, a 440 Hz tone will sound for 2
  327. eighteenths of a second.
  328.  
  329. You may specify multiple frequency/duration pairs on the same
  330. line.
  331.  
  332.    Note     Frequency (highest octave)
  333.    =====    =========
  334.      A         3520
  335.    A#,B-       3714
  336.      B         3952
  337.      C         4186
  338.    C#,D-       4434
  339.      D         4698
  340.    D#,E-       4978
  341.      E         5274
  342.      F         5588
  343.    F#,G-       5920
  344.      G         6272
  345.    G#,A-       6644
  346.  
  347. You can drop down an octave by halving the frequency for a given
  348. note. A "#" suffix indicates a sharp, and "-" a flat note.
  349.  
  350.                               BMCD                      page 9
  351.  
  352.  
  353.  
  354. The BMCD command combines the functions of the DOS commands, MD
  355. (or MKDIR) and CD (or CHDIR): It creates a directory and makes
  356. it the current default directory. BMCD can accept multiple
  357. directory specifications.
  358.  
  359. Syntax:
  360.    BMCD [directory] {directory} {etc}
  361.  
  362. Example:
  363.    BMCD A:\GAME B:\DOC
  364.  
  365. The above example creates the subdirectories A:\GAME and B:\DOC,
  366. and makes them the default subdirectories for drives A: and B:,
  367. respectively.
  368.  
  369.  
  370.  
  371.  
  372. The BMD command is similar to the DOS command, MD (or MKDIR).
  373.  
  374. Unlike the DOS command it replaces, BMD can accept multiple
  375. directory specifications.
  376.  
  377. Syntax:
  378.    BMD [directory] {directory} {etc}
  379.  
  380. Example:
  381.    BMD ONE TWO
  382.  
  383. The above example creates the subdirectories ONE and TWO.
  384.  
  385.  
  386.  
  387.  
  388.                               BRD
  389.  
  390.  
  391.  
  392. The BRD command is similar to the DOS command, RD (or RMDIR).
  393.  
  394. Unlike the DOS command it replaces, BRD can accept multiple
  395. directory specifications.
  396.  
  397. Syntax:
  398.    BRD [directory] {directory} {etc}
  399.  
  400. Example:
  401.    BRD ONE TWO
  402.  
  403. The above example removes the subdirectories ONE and TWO.
  404.  
  405.                              BREN                      page 10
  406.  
  407.  
  408.  
  409. The BREN command is similar to the DOS command, REN (or RENAME).
  410.  
  411. Unlike the DOS command it replaces, BREN can accept multiple
  412. source files, accepts full paths for both source and destination
  413. filespecs, allows renaming from one drive to another, can rename
  414. hidden, read-only, and system files, allows overwriting existing
  415. files, accepts exception specifications, and allows prompting
  416. for confirmation before renaming or before overwriting existing
  417. files.
  418.  
  419. When specifying multiple source files, the source files must be
  420. enclosed in parentheses, and the destination must be a directory
  421. rather than a filespec.
  422.  
  423. By default, the rename will fail if the destination file already
  424. exists. You can override this with /R (add /Y if you don't want
  425. to confirm each overwrite yourself).
  426.  
  427. Syntax:
  428.    BREN {options} [source(s)] [destination] {/E [exception(s)]}
  429.  
  430. Options:
  431.    /E   rename everything EXCEPT for the following files
  432.    /H   rename hidden, read-only, and system files too
  433.    /L   display filenames in lowercase
  434.    /N   don't actually rename anything (for testing BREN)
  435.    /P   prompt for confirmation before renaming each file
  436.    /Q   quiet: don't display filenames or summary
  437.    /R   prompt before overwriting existing files
  438.    /Y   assume YES to all requests for confirmation
  439.  
  440. The following parameters may be set as defaults for BREN by
  441. setting the BREN environment variable: /H /L /P /Q /R /Y
  442.  
  443. Example:
  444.    BREN (A: B:) C:\MISC /E *.TXT
  445.  
  446. The above example moves all files on both A: and B: drives to
  447. the directory C:\MISC, except for files ending in .TXT. The
  448. rename is not done for files that already exist in C:\MISC.
  449.  
  450. Example:
  451.    BREN /R /Y *.BAK \BACKUP
  452.  
  453. The above example moves all .BAK files from the current
  454. directory to the \BACKUP directory, overwriting any existing
  455. files by the same name.
  456.  
  457.                              BTYPE                     page 11
  458.  
  459.  
  460.  
  461. The BTYPE command is similar to the DOS command, TYPE.
  462.  
  463. Unlike the DOS command it replaces, BTYPE provides pagination.
  464.  
  465. Syntax:
  466.    BTYPE {options} [file(s)]
  467.  
  468. Options:
  469.    /P   prompt to continue at end of each full screen
  470.  
  471.  
  472.  
  473.  
  474.                               CAL
  475.  
  476.  
  477.  
  478. The CAL command displays a calendar. If no parameters are given,
  479. the calendar is for the current month and year. Month and/or
  480. year values can be specified as well.
  481.  
  482. Syntax:
  483.    CAL {month} {year}
  484.  
  485. If the month is specified, it must be spelled out. It may be
  486. abbreviated to as few as three characters (JAN, FEB, etc).
  487.  
  488. You may enter either two digits or four digits for the year. If
  489. two digits are used, the 21st century will be assumed for 0-9,
  490. or the 20th century otherwise. The calendar program accepts a
  491. year range of 1900-2078.
  492.  
  493.                              CALC                      page 12
  494.  
  495.  
  496.  
  497. The CALC command is a calculator.
  498.  
  499. Syntax:
  500.    CALC expression
  501.  
  502. Expressions may use the following operators:
  503.    +    add
  504.    -    subtract
  505.    *    multiply
  506.    /    divide
  507.    ^    raise to a power
  508.    **   raise to a power (alternate form)
  509.  
  510. Parentheses may be used to override the default algebraic
  511. precedence, which is: negation, raise to power, multiply and
  512. divide, add and subtract.
  513.  
  514. Example:
  515.    CALC 19.95 * 1.05 + 3
  516.  
  517.  
  518.  
  519.  
  520.                            CAPSLOCK
  521.  
  522.  
  523.  
  524. The CAPSLOCK command lets you get or set the Caps Lock state.
  525.  
  526. Syntax:
  527.    CAPSLOCK {ON or OFF}
  528.  
  529. The current Caps Lock state is displayed if you do not give a
  530. parameter. Otherwise, Caps Lock is set as you request.
  531.  
  532.                              COLOR                     page 13
  533.  
  534.  
  535.  
  536. The COLOR command allows you to set the display colors. An ANSI
  537. driver must be installed for it to function.
  538.  
  539. Syntax:
  540.    COLOR {BRIGHT} {BLINKING} foregroundcolor {ON backgroundcolor}
  541.  
  542. Colors:
  543.    BLACK   BLUE   GREEN   RED   MAGENTA   CYAN   YELLOW   WHITE
  544.  
  545. Color parameters may be shortened to as little as three
  546. characters each. BROWN may be used instead of YELLOW (on most
  547. displays, the "normal" color appears brown, and the "bright"
  548. version of the same color appears yellow).
  549.  
  550. Example:
  551.    COLOR BRIGHT WHITE ON RED
  552.  
  553. The above example sets the foreground color to bright white, and
  554. the background color to red. A shorter version of the same thing
  555. might look like this:
  556.    COLOR BRI WHI ON RED
  557.  
  558.                            DESCRIBE                    page 14
  559.  
  560.  
  561.  
  562. The DESCRIBE command allows you to attach a description to a
  563. file or subdirectory name. This description will be shown when
  564. you use the BDIR directory command. It is also compatible with
  565. the 4DOS and NDOS command shells, and will be shown by the DIR
  566. command provided with those shells.
  567.  
  568. Descriptions may be up to 120 characters, although the part of
  569. the description that is shown depends on the BDIR parameters. It
  570. is 31-37 characters in 80-column mode, depending on whether file
  571. attributes are also being shown. In 132-column mode, up to 81
  572. characters of the file description are displayed.
  573.  
  574. Descriptions are kept in a hidden file named DESCRIPT.ION. They
  575. are automatically maintained by BCMD file utilities (BDEL, BREN,
  576. BCOPY, etc) and other software that is aware of descriptions
  577. (4DOS, NDOS, etc). Descriptions may not be properly updated if
  578. you do file handling with other software.
  579.  
  580. Syntax:
  581.    DESCRIBE {options} [file(s)] {/E [except file(s)]} {"desc"}
  582.  
  583. Options:
  584.    /E   describe everything EXCEPT for the following files
  585.    /L   display filenames in lowercase
  586.    /Q   quiet: don't display filenames or summary
  587.  
  588. The description may be included on the DESCRIBE command line, or
  589. you may leave it off-- in which case, you will be prompted for a
  590. description for each of the selected files.
  591.  
  592. Example:
  593.    DESCRIBE BCMD.DOC "Documentation for BCMD utilities"
  594.  
  595. In the above example, the file BCMD.DOC will be tagged with the
  596. description "Documentation for BCMD utilities" (without the
  597. quotation marks).
  598.  
  599. Example:
  600.    DESCRIBE *.DOC
  601.  
  602. In the above example, the DESCRIBE command will ask you for a
  603. description for each of the .DOC files in the current directory.
  604.  
  605.                              ECHOS                     page 15
  606.  
  607.  
  608.  
  609. The ECHOS command is for use in batch files. It displays text
  610. like the ECHO command, but without moving to the next line. This
  611. makes it easy to display multiple items on the same line. In
  612. order for this to be effective, the batch ECHO state must be
  613. turned off so that the batch commands aren't shown.
  614.  
  615. Syntax:
  616.    ECHOS message
  617.  
  618. Example:
  619.    ECHO OFF
  620.    ECHOS This is
  621.    ECHOS  a test
  622.  
  623. This example displays:
  624.  
  625. This is a test
  626.  
  627.  
  628.  
  629.  
  630.                              FREE
  631.  
  632.  
  633.  
  634. The FREE command shows the amount of disk space available and
  635. the amount used.
  636.  
  637. Syntax:
  638.    FREE {drive{:}} {drive{:}} {etc}
  639.  
  640. If no drive specs are given, stats for the current drive will be
  641. shown. One or more drives may be specified. A colon (":") may,
  642. optionally, be placed after each drive letter.
  643.  
  644. Example:
  645.    FREE C: D:
  646.  
  647.                            KEYSPEED                    page 16
  648.  
  649.  
  650.  
  651. The KEYSPEED command sets the keyboard repeat rate. It will not
  652. work on 8088 PCs.
  653.  
  654. The default keyboard repeat rate is quite sluggish, and you'll
  655. be amazed at how much more responsive your machine is with
  656. faster settings! You can also reduce responsiveness in order to
  657. make the keyboard more manageable for young children, etc.
  658.  
  659. Syntax:
  660.    KEYSPEED delay repeatrate
  661.  
  662. The starting delay may be 0-3, and is 2 by default. The repeat
  663. rate may be 0-31, and is 10 by default. In both cases, settings
  664. of zero are fastest.
  665.  
  666. Example:
  667.    KEYSPEED 0 0
  668.  
  669. The above example sets the keyboard repeat as fast as possible.
  670.  
  671. Example:
  672.    KEYSPEED 2 10
  673.  
  674. The above example restores the default keyboard repeat rate.
  675.  
  676.  
  677.  
  678.  
  679.  
  680.                             LOCASE
  681.  
  682.  
  683.  
  684. The LOCASE filter converts text to lowercase. It works only with
  685. ASCII characters, so it does not fully support international
  686. character sets.
  687.  
  688. Filters are used in conjunction with redirection or piping. They
  689. accept an incoming stream of text, modify it, and pass it on.
  690.  
  691. Example:
  692.    LOCASE <BCMD.NEW
  693.  
  694. The above example converts the BCMD.NEW file to lowercase and
  695. displays the results.
  696.  
  697. Example:
  698.    BDIR | LOCASE
  699.  
  700. The above example converts the output of the BDIR command to
  701. lowercase and displays the results.
  702.  
  703.                             LOCATE                     page 17
  704.  
  705.  
  706.  
  707. The LOCATE command sets the cursor position. It is intended for
  708. use primarily in designing displays for batch files. An ANSI
  709. driver, such as ANSI.SYS, must be installed.
  710.  
  711. Syntax:
  712.    LOCATE row column
  713.  
  714. Cursor coordinates are based on (1,1), which is the upper left
  715. corner of the display. A typical display has rows 1-25 and
  716. columns 1-80.
  717.  
  718. Example:
  719.    LOCATE 5 1
  720.  
  721. The above example positions the cursor on the first column of
  722. the fifth row of the screen.
  723.  
  724.  
  725.  
  726.  
  727.                              LTRIM
  728.  
  729.  
  730.  
  731. The LTRIM filter removes blanks from the left side of each line
  732. of text. Blanks are construed as space or tab characters.
  733.  
  734. Filters are used in conjunction with redirection or piping. They
  735. accept an incoming stream of text, modify it, and pass it on.
  736.  
  737. Example:
  738.    LTRIM <BCMD.NEW
  739.  
  740. The above example trims blanks from the left side of each line
  741. of the BCMD.NEW file and displays the results.
  742.  
  743. Example:
  744.    BDIR | LTRIM
  745.  
  746. The above example trims blanks from the left side of each line
  747. of the output of the BDIR command and displays the results.
  748.  
  749.                             NUMLOCK                    page 18
  750.  
  751.  
  752.  
  753. The NUMLOCK command lets you get or set the Num Lock state.
  754.  
  755. Syntax:
  756.    NUMLOCK {ON or OFF}
  757.  
  758. The current Num Lock state is displayed if you do not give a
  759. parameter. Otherwise, Num Lock is set as you request.
  760.  
  761.  
  762.  
  763.  
  764.                            ONESPACE
  765.  
  766.  
  767.  
  768. The ONESPACE filter converts multiple spaces in a line of text
  769. to single spaces.
  770.  
  771. Filters are used in conjunction with redirection or piping. They
  772. accept an incoming stream of text, modify it, and pass it on.
  773.  
  774. Example:
  775.    ONESPACE <BCMD.NEW
  776.  
  777. The above example takes each line of the file BCMD.NEW, converts
  778. sequences of two or more spaces to one space, and displays the
  779. results.
  780.  
  781. Example:
  782.    BDIR | ONESPACE
  783.  
  784. The above example takes the output of the BDIR command, converts
  785. sequences of two or more spaces in a line to a single space, and
  786. displays the results.
  787.  
  788.                              TYME                      page 19
  789.  
  790.  
  791.  
  792. The TYME command displays the current time and date in a readily
  793. understandable format.
  794.  
  795. Syntax:
  796.    TYME
  797.  
  798. The output of TYME looks like this:
  799.  
  800. It is 11:11 am on Saturday, August 14, 1993.
  801.  
  802.  
  803.  
  804.  
  805.                             UNANSI
  806.  
  807.  
  808.  
  809. The UNANSI filter removes ANSI sequences from text. This can be
  810. useful in cleaning up text that was captured from a BBS and
  811. removing colors from BDIR output if color is on by default, and
  812. so on.
  813.  
  814. Filters are used in conjunction with redirection or piping. They
  815. accept an incoming stream of text, modify it, and pass it on.
  816.  
  817. Example:
  818.    UNANSI <CAPTURE.BBS
  819.  
  820. The above example removes all ANSI sequences from the file
  821. CAPTURE.BBS and displays the results.
  822.  
  823. Example:
  824.    BDIR | UNANSI
  825.  
  826. The above example removes ANSI sequences from the output of the
  827. BDIR command and displays the results.
  828.  
  829.                              UNCPM                     page 20
  830.  
  831.  
  832.  
  833. The UNCPM command removes control-Z characters from the end of
  834. files. This is normally used only on text files.
  835.  
  836. The old CP/M operating system did not keep track of the exact
  837. size of files, so the end of text files was normally marked with
  838. a control-Z character. This carried over into the early days of
  839. MS-DOS, which was designed to make the transition from CP/M as
  840. easy as possible. Unfortunately, some programs still use Ctrl-Z
  841. as an end-of-file marker, even though MS-DOS keeps track of
  842. exact file sizes. This can lead to trouble.
  843.  
  844. If there happens to be a Ctrl-Z embedded in a file which is
  845. handled by a CP/M-style program, the file will be truncated at
  846. the Ctrl-Z. This can quite readily occur if an editor adds a
  847. Ctrl-Z to the end of a file which is subsequently appended to by
  848. a program which doesn't expect CP/M terminators, for example.
  849. The UNCPM utility helps avoid such errors.
  850.  
  851. Syntax:
  852.    UNCPM {options} [file(s)] {/E [exception file(s)]}
  853.  
  854. Options:
  855.    /E   UnCPM everything EXCEPT for the following files
  856.    /H   UnCPM hidden, read-only, and system files too
  857.    /L   display filenames in lowercase
  858.    /N   don't actually UnCPM anything (for testing UNCPM)
  859.    /P   prompt for confirmation before UnCPMing each file
  860.    /Q   quiet: don't display filenames or summary
  861.    /S   recurse through subdirectories
  862.    /Y   assume YES to all requests for confirmation
  863.  
  864. Example:
  865.    UNCPM *.TXT *.DOC
  866.  
  867. The above example removes Ctrl-Z terminators from all files
  868. ending in .TXT and .DOC in the current directory.
  869.  
  870.                             UPCASE                     page 21
  871.  
  872.  
  873.  
  874. The UPCASE filter converts text to uppercase. It works only with
  875. ASCII characters, so it does not fully support international
  876. character sets.
  877.  
  878. Filters are used in conjunction with redirection or piping. They
  879. accept an incoming stream of text, modify it, and pass it on.
  880.  
  881. Example:
  882.    UPCASE <BCMD.NEW
  883.  
  884. The above example converts the BCMD.NEW file to uppercase and
  885. displays the results.
  886.  
  887. Example:
  888.    BDIR | UPCASE
  889.  
  890. The above example converts the output of the BDIR command to
  891. uppercase and displays the results.
  892.  
  893.